package initialize

import (
	"fmt"
	"github.com/streadway/amqp"
	"os"
)

func MustNewRabbiemq(dsn string) *amqp.Connection {
	conn, err := amqp.Dial(dsn)
	if err != nil {
		fmt.Println("无法连接到 RabbitMQ: ", err)
		os.Exit(-1)
	}
	return conn
}
